using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._BusinessAnalystTools._Modeling
{
    /// <summary>
    /// <para>Huff Model Calibration</para>
    /// <para>Calculates exponent values for use in the Huff Model tool.</para>
    /// <para>计算用于 Huff 模型工具的指数值。</para>
    /// </summary>    
    [DisplayName("Huff Model Calibration")]
    public class HuffModelCalibration : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public HuffModelCalibration()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_facility_features">
        /// <para>Input Facility Features</para>
        /// <para>The input point feature class representing competitors or existing stores.</para>
        /// <para>表示竞争对手或现有商店的输入点要素类。</para>
        /// </param>
        /// <param name="_facility_id_field">
        /// <para>Facility ID Field</para>
        /// <para>A unique ID field representing a store or facility location.</para>
        /// <para>表示商店或设施位置的唯一 ID 字段。</para>
        /// </param>
        /// <param name="_in_customer_features">
        /// <para>Input Customer Features</para>
        /// <para>The input point feature class representing customer locations.</para>
        /// <para>表示客户位置的输入点要素类。</para>
        /// </param>
        /// <param name="_link_field">
        /// <para>Associated Facility ID Field</para>
        /// <para>The field that will be used as an ID to assign individual customers to a facility or store.</para>
        /// <para>将用作将单个客户分配到设施点或商店的 ID 的字段。</para>
        /// </param>
        /// <param name="_in_sales_potential_features">
        /// <para>Input Sales Potential Features</para>
        /// <para>The input polygon feature class used to determine the potential sales market.</para>
        /// <para>用于确定潜在销售市场的输入面要素类。</para>
        /// </param>
        /// <param name="_sales_potential_id_field">
        /// <para>Sales Potential ID Field</para>
        /// <para>A unique ID field representing the sales potential area.</para>
        /// <para>表示潜在销售区域的唯一 ID 字段。</para>
        /// </param>
        /// <param name="_out_calibration">
        /// <para>Output Calibration</para>
        /// <para>The output calibration file that will contain the calibrated Huff model results, which is the exponent values for the attractiveness variables and distance. The output file extension will be *.huffmodel.</para>
        /// <para>输出校准文件，其中包含校准的 Huff 模型结果，该结果是吸引力变量和距离的指数值。输出文件扩展名将为 *.huffmodel。</para>
        /// </param>
        /// <param name="_attractiveness_variables">
        /// <para>Attractiveness Variables</para>
        /// <para>The fields that will be used to determine the attractiveness of each competitor. In many cases, the size of the store is used as a substitute for attractiveness.</para>
        /// <para>将用于确定每个竞争对手的吸引力的字段。在许多情况下，商店的规模被用作吸引力的替代品。</para>
        /// </param>
        public HuffModelCalibration(object _in_facility_features, object _facility_id_field, object _in_customer_features, object _link_field, object _in_sales_potential_features, object _sales_potential_id_field, object _out_calibration, object _attractiveness_variables)
        {
            this._in_facility_features = _in_facility_features;
            this._facility_id_field = _facility_id_field;
            this._in_customer_features = _in_customer_features;
            this._link_field = _link_field;
            this._in_sales_potential_features = _in_sales_potential_features;
            this._sales_potential_id_field = _sales_potential_id_field;
            this._out_calibration = _out_calibration;
            this._attractiveness_variables = _attractiveness_variables;
        }
        public override string ToolboxName => "Business Analyst Tools";

        public override string ToolName => "Huff Model Calibration";

        public override string CallName => "ba.HuffModelCalibration";

        public override List<string> AcceptEnvironments => ["baDataSource", "baNetworkSource", "workspace"];

        public override object[] ParameterInfo => [_in_facility_features, _facility_id_field, _in_customer_features, _link_field, _in_sales_potential_features, _sales_potential_id_field, _out_calibration, _attractiveness_variables, _customer_weight_field, _distance_type, _distance_units, _travel_direction.GetGPValue(), _time_of_day, _time_zone.GetGPValue()];

        /// <summary>
        /// <para>Input Facility Features</para>
        /// <para>The input point feature class representing competitors or existing stores.</para>
        /// <para>表示竞争对手或现有商店的输入点要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Facility Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_facility_features { get; set; }


        /// <summary>
        /// <para>Facility ID Field</para>
        /// <para>A unique ID field representing a store or facility location.</para>
        /// <para>表示商店或设施位置的唯一 ID 字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Facility ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _facility_id_field { get; set; }


        /// <summary>
        /// <para>Input Customer Features</para>
        /// <para>The input point feature class representing customer locations.</para>
        /// <para>表示客户位置的输入点要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Customer Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_customer_features { get; set; }


        /// <summary>
        /// <para>Associated Facility ID Field</para>
        /// <para>The field that will be used as an ID to assign individual customers to a facility or store.</para>
        /// <para>将用作将单个客户分配到设施点或商店的 ID 的字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Associated Facility ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _link_field { get; set; }


        /// <summary>
        /// <para>Input Sales Potential Features</para>
        /// <para>The input polygon feature class used to determine the potential sales market.</para>
        /// <para>用于确定潜在销售市场的输入面要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Sales Potential Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_sales_potential_features { get; set; }


        /// <summary>
        /// <para>Sales Potential ID Field</para>
        /// <para>A unique ID field representing the sales potential area.</para>
        /// <para>表示潜在销售区域的唯一 ID 字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Sales Potential ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _sales_potential_id_field { get; set; }


        /// <summary>
        /// <para>Output Calibration</para>
        /// <para>The output calibration file that will contain the calibrated Huff model results, which is the exponent values for the attractiveness variables and distance. The output file extension will be *.huffmodel.</para>
        /// <para>输出校准文件，其中包含校准的 Huff 模型结果，该结果是吸引力变量和距离的指数值。输出文件扩展名将为 *.huffmodel。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Calibration")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_calibration { get; set; }


        /// <summary>
        /// <para>Attractiveness Variables</para>
        /// <para>The fields that will be used to determine the attractiveness of each competitor. In many cases, the size of the store is used as a substitute for attractiveness.</para>
        /// <para>将用于确定每个竞争对手的吸引力的字段。在许多情况下，商店的规模被用作吸引力的替代品。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Attractiveness Variables")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _attractiveness_variables { get; set; }


        /// <summary>
        /// <para>Customer Weight Field</para>
        /// <para>A calculated weighted value field assigned to each customer.</para>
        /// <para>分配给每个客户的计算加权值字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Customer Weight Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _customer_weight_field { get; set; } = null;


        /// <summary>
        /// <para>Distance Type</para>
        /// <para>The method of travel that will be used to calculate distance. The default value is Straight Line.</para>
        /// <para>将用于计算距离的旅行方法。默认值为 Straight Line。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Distance Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _distance_type { get; set; } = null;


        /// <summary>
        /// <para>Distance Units</para>
        /// <para>The distance-measuring units that will be used when calculating distance.</para>
        /// <para>计算距离时将使用的距离测量单位。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Distance Units")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _distance_units { get; set; } = null;


        /// <summary>
        /// <para>Travel Direction</para>
        /// <para><xdoc>
        ///   <para>Specifies the direction of travel that will be used between stores and sales potential features.</para>
        ///   <bulletList>
        ///     <bullet_item>Toward Stores—The direction of travel will be from sales potential features to stores. This is the default.</bullet_item><para/>
        ///     <bullet_item>Away from Stores—The direction of travel will be from stores to sales potential features.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将在商店和潜在销售要素之间使用的行进方向。</para>
        ///   <bulletList>
        ///     <bullet_item>面向商店 - 行进方向将从销售潜在功能到商店。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>远离商店 - 行进方向将从商店到销售潜在功能。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Travel Direction")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _travel_direction_value _travel_direction { get; set; } = _travel_direction_value._TOWARD_STORES;

        public enum _travel_direction_value
        {
            /// <summary>
            /// <para>Toward Stores</para>
            /// <para>Toward Stores—The direction of travel will be from sales potential features to stores. This is the default.</para>
            /// <para>面向商店 - 行进方向将从销售潜在功能到商店。这是默认设置。</para>
            /// </summary>
            [Description("Toward Stores")]
            [GPEnumValue("TOWARD_STORES")]
            _TOWARD_STORES,

            /// <summary>
            /// <para>Away from Stores</para>
            /// <para>Away from Stores—The direction of travel will be from stores to sales potential features.</para>
            /// <para>远离商店 - 行进方向将从商店到销售潜在功能。</para>
            /// </summary>
            [Description("Away from Stores")]
            [GPEnumValue("AWAY_FROM_STORES")]
            _AWAY_FROM_STORES,

        }

        /// <summary>
        /// <para>Time of Day</para>
        /// <para>The time and date that will be used when calculating distance.</para>
        /// <para>计算距离时将使用的时间和日期。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Time of Day")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _time_of_day { get; set; } = null;


        /// <summary>
        /// <para>Time Zone</para>
        /// <para><xdoc>
        ///   <para>Specifies the time zone that will be used for the Time of Day parameter.</para>
        ///   <bulletList>
        ///     <bullet_item>Time Zone at Location—The time zone in which the territories are located will be used. This is the default.</bullet_item><para/>
        ///     <bullet_item>UTC—Coordinated universal time (UTC) will be used.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将用于“时间”参数的时区。</para>
        ///   <bulletList>
        ///     <bullet_item>位置时区—将使用区域所在的时区。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>UTC—将使用协调世界时 （UTC）。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Time Zone")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _time_zone_value _time_zone { get; set; } = _time_zone_value._TIME_ZONE_AT_LOCATION;

        public enum _time_zone_value
        {
            /// <summary>
            /// <para>UTC</para>
            /// <para>UTC—Coordinated universal time (UTC) will be used.</para>
            /// <para>UTC—将使用协调世界时 （UTC）。</para>
            /// </summary>
            [Description("UTC")]
            [GPEnumValue("UTC")]
            _UTC,

            /// <summary>
            /// <para>Time Zone at Location</para>
            /// <para>Time Zone at Location—The time zone in which the territories are located will be used. This is the default.</para>
            /// <para>位置时区—将使用区域所在的时区。这是默认设置。</para>
            /// </summary>
            [Description("Time Zone at Location")]
            [GPEnumValue("TIME_ZONE_AT_LOCATION")]
            _TIME_ZONE_AT_LOCATION,

        }

        public HuffModelCalibration SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}